const router = require('koa-router')()

/*
router.get('/', async (ctx, next) => {
  await ctx.render('index', {
    title: 'Hello Koa 2!'
  })
})
*/
router.prefix('/api/areas')

router.get('/', async (ctx, next) => {
  console.log(ctx.url)
  ctx.body = 'get areas'
})
router.post('/',(async,next)=>{
  msg:'add areas'   
})
router.put('/:id',(async,next)=>{
  msg:'put areas'   
})
router.delete('/:id',(async,next)=>{
  msg:'delete areas'   
})

module.exports = router
